<template>
	<view>
		<uni-nav-bar title="消息" :border="false" :fixed="true" bg="bg-fff" color="#333"></uni-nav-bar>
		<view class="padding-24 solid-bottom flex align-center justify-between" @click="jump('/pages/msg/msgList')">
			<view class="flex align-center">
				<image style="width: 80rpx;height: 80rpx;" src="../../static/img/msg1.png"></image>
				<text class="fs-28 color-333 margin-left-20">系统消息</text>
			</view>
			<view>
				<!-- <view class="fs-24 color-999">01:07</view> -->
				<view v-if="info.system > 0" class="fs-20 color-fff bg-zhuse text-center margin-top-16" style="padding: 2rpx 12rpx;border-radius: 40rpx;">{{info.system}}</view>
			</view>
		</view>
		<view class="padding-24 solid-bottom flex align-center justify-between" @click="jump('/pages/msg/msgList2')">
			<view class="flex align-center">
				<image style="width: 80rpx;height: 80rpx;" src="../../static/img/msg2.png"></image>
				<text class="fs-28 color-333 margin-left-20">消费</text>
			</view>
			<view>
				<!-- <view class="fs-24 color-999">01:07</view> -->
				<view v-if="info.pay > 0" class="fs-20 color-fff bg-zhuse text-center margin-top-16" style="padding: 2rpx 12rpx;border-radius: 40rpx;">{{info.pay}}</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				info:{}
			}
		},
		onShow() {
			this.init()	
		},
		methods:{
			init(){
				this.$api.unread_msg().then(res => {
					if (res.code == 1) {
						this.info = res.data;
					}
				})
			}
		}
	}
	
</script>

<style>
</style>
